

struct node
{
	char* dirname;
	char fullpath[100];
	struct file_descriptor *nodefile_descriptor;
	struct node* left_child;
	struct node* right_sibling;
};
struct node* root ;

int levelcount;
char* path;

void createroot();
void display(struct node* );
void displaynonrec(struct node*);
void displayf(struct node* , FILE*);
void displaynonrecf(struct node*, FILE*);

void displaystub(char* path, int ,char*);
void insert(struct node* root, char* path,struct file_descriptor*);
struct node* search(struct node* root, char* path);
void delete(struct node*, char path);
void narrayinsert(char* path,struct file_descriptor*);
struct node* Searchnarray(char* path);
struct node* Search_by_path(struct node*,char* path);
int deletenarray(char* path);
void mountnarray(struct file_descriptor_list*);
char* Findparentpath(char* path);
int countlevel(char* path);
char* Trimpath(char* path);
void insertleft(struct node*, char*, struct file_descriptor*);
char* reducePathlength(char* path);
struct node* Deleteinfo(struct node*, int *, unsigned long int);
void repopulateFDlist(struct node*);
void repopulateFDlist2(struct node*);

void fill_space(struct node *,struct node *); // defination in file_descriptor.c

char* foldernamefrompath(char*);
void correctpath(struct node*, struct node*);
void movenode(char* , char* );
